import sys
from PyQt5.QtWidgets import QApplication
from PyQt5.QtCore import Qt

from MyMainWindow import Window
#from fuben.huizhi_curve import WellDataPlot

QApplication.setHighDpiScaleFactorRoundingPolicy(
    Qt.HighDpiScaleFactorRoundingPolicy.PassThrough)
QApplication.setAttribute(Qt.AA_EnableHighDpiScaling)
QApplication.setAttribute(Qt.AA_UseHighDpiPixmaps)

if __name__ == '__main__':
    app = QApplication(sys.argv)
    w = Window()

    w.show()

    if w.sign_iftheDatatoDatabase:
        depth = w.retrunDepth()
        curveData = w.returnCurve()

        curve = WellDataPlot(depth, curveData)

        curve.show()

    app.exec_()

